Skip to content

Custom python script caller for write#1033

Merged
jginternational merged 3 commits into
masterfrom
write-custom-python
May 29, 2026
Merged

Custom python script caller for write#1033
jginternational merged 3 commits into
masterfrom
write-custom-python

Conversation

@jginternational
Copy link
Copy Markdown
Member

By adding python scripts as seen in the example:
image

The GiD kratos menú will show this
image

@RiccardoRossi

Copilot AI review requested due to automatic review settings May 21, 2026 14:09
@jginternational jginternational self-assigned this May 21, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a mechanism to discover and execute user-provided Python scripts from the GiD “Kratos” menu, intended (initially) to support custom mesh writing workflows.

Changes:

  • Add Kratos::GetCustomScripts to discover scripts/Custom/*.py and populate a new “Custom scripts” submenu.
  • Add Kratos::ExecuteCustomScript to source and call a selected Python script from Tcl.
  • Add an example custom script (python_writer.py) under scripts/Custom/.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 5 comments.

File Description
kratos.gid/scripts/Utils.tcl Adds the Tcl entry point that sources and executes a selected custom Python script.
kratos.gid/scripts/Menus.tcl Adds menu entries for custom scripts and discovers available .py files.
kratos.gid/scripts/Custom/python_writer.py Provides an example custom Python script callable from the new menu.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread kratos.gid/scripts/Utils.tcl
Comment thread kratos.gid/scripts/Utils.tcl Outdated
Comment thread kratos.gid/scripts/Utils.tcl Outdated
Comment thread kratos.gid/scripts/Menus.tcl
Comment thread kratos.gid/scripts/Custom/python_writer.py
jginternational and others added 2 commits May 29, 2026 10:04
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@jginternational jginternational merged commit 437dc03 into master May 29, 2026
1 of 2 checks passed
@jginternational jginternational deleted the write-custom-python branch May 29, 2026 10:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants